<?php
/**
 * @package WordPress
 * @subpackage Hello_D
 */

if ( function_exists('register_sidebar') )
	register_sidebar(array(
        'before_widget' => '<li id="%1$s" class="widget %2$s">',
        'after_widget' => '</li>',
        'before_title' => '<h2>',
        'after_title' => '</h2>',
    ));

function parse_twitter_feed() {
	$xml = file_get_contents('http://twitter.com/statuses/user_timeline/124581189.rss');
	$feed = simplexml_load_string($xml);
		
	$entries = array();
		
	foreach ($feed->channel->item as $item) {
		$entries[] = str_replace("\n", "<br />", substr($item->title, 8));
	}
	
	echo implode("<hr />", array_slice($entries, 0,5));
}

?>
